import Vue from 'vue'
import VueRouter from 'vue-router'
import Index from '@/views/Index';


Vue.use(VueRouter)

export default new VueRouter({
  mode: "history",
  routes: [{
      path: "/login",
      alias: "/",
      component:()=>import("@/views/login/Login")
    },
    {
      path: "/index",
      alias:"/home",
      component: Index,
      children: [{
          path: "",
          component:()=>import("@/views/Home")
        },
        {
          path: "/news",
          component:()=>import("@/views/news/News")
        },
        {
          path: "userinfo",
          component:()=>import("@/views/My/UserInfo")
        }, 
        {
          path: "/order",
          component:()=>import("@/views/ding/Order")
        },
        {
          path:"/service",
          component:()=>import("@/views/service/Service")
        },
        {
          path: "xuanze",
          component:()=>import("@/views/xiadan/Xuanze")
        },
        // 设置
        {
          path:"setone",
          component:()=>import("@/views/set/Setone")
        },
        {
          path:"settwo",
          component:()=>import("@/views/set/Settwo")
        },
        {
          path:"setthree",
          component:()=>import("@/views/set/Setthree")
        },
        {
          path:"setfour",
          component:()=>import("@/views/set/Setfour")
        },
        {
          path:"setfive",
          component:()=>import("@/views/set/Setfive")
        },
        {
          path:"safe1",
          component:()=>import("@/views/safe/Safe1")
        },
        {
          path:"safe2",
          component:()=>import("@/views/safe/Safe2")
        },
        {
          path:"safe3",
          component:()=>import("@/views/safe/Safe3")
        }
      ]
    },
    {
      path: "/setting",
      component:()=>import("@/views/set/Setting"),
    },
    {
      path: "/safe",
      component:()=>import("@/views/safe/Safe")
    },
    {
      path:"/cash",
      component:()=>import("@/views/cash/Cash")
    },
    {
      path:"/show7",
      component:()=>import("@/views/service/Show7")
    },
    {
      path:"/show8",
      component:()=>import("@/views/service/Show8")
    },
    {
      path:"/liaotian",
      component:()=>import("@/views/service/Liaotian")
    },
    {
      path:"/queding",
      component:()=>import("@/views/xiadan/Queding")
    },

    // 司机端路由
    {
      path:"/siji",
      component:()=>import("@/views/login/Siji")
    },
    {
      path:"/shome",
      component:()=>import("@/views/sijiduan/Shome")
    },
    {
      path:"/go",
      component:()=>import("@/views/sijiduan/Go")
    },
    {
      path:"/jiedan",
      component:()=>import("@/views/sijiduan/Jiedan")
    },
    {
      path:"/querenzd",
      component:()=>import("@/views/sijiduan/Querenzd")
    },
    {
      path:"/mines",
      component:()=>import("@/views/sijiduan/Mines")
    },
    {
      path:"/sjxx",
      component:()=>import("@/views/sijiduan/Sjxx")
    },
    {
      path:"/qianbao",
      component:()=>import("@/views/sijiduan/Qianbao")
    },
    {
      path:"/xinxi",
      component:()=>import("@/views/login/Xinxi")
    },
    {
      path:"/dingdan",
      component:()=>import("@/views/sijiduan/Dingdan")
    },
    {
      path:"/yonghu",
      component:()=>import("@/views/login/Yonghu")
    },
    {
      path:"/sjidenglu",
      component:()=>import("@/views/login/Sjidenglu")
    },
  ]
});